<template>
  <van-nav-bar  @click-left="clickleft" :title="title" left-text="返回" left-arrow></van-nav-bar>
</template>

<script>
import { NavBar } from "vant";
export default {
  name: "NavBar",
  components: {
    [NavBar.name]: NavBar
  },
  props:{
    title:String
  },
  methods: {
    clickleft(){
      this.$router.back()
    }
  },
};
</script>

<style>
.van-nav-bar{
  background-color: #009eef;
}
.van-nav-bar__text,.van-nav-bar .van-icon{
  color: #fff;
} 
</style>